home *** CD-ROM | disk | FTP | other *** search
/ Beginning Mac Programming / Beginning Mac Programming.bin / pc / Open Me for REALbasic 3 / REALbasic 3.2 / Goodies / Development Tools / XCMDs and XFCNs / Other / GetDefaultFile / cards.xml < prev    next >
Encoding:
Text File  |  1996-03-03  |  7.4 KB  |  233 lines

  1. card_4174.xml
  2. <?xml version="1.0" encoding="utf-8" ?>
  3. <!DOCTYPE card PUBLIC "-//Apple, Inc.//DTD card V 2.0//EN" "" >
  4. <card>
  5.     <id>4174</id>
  6.     <filler1>0</filler1>
  7.     <bitmap>BMAP_4818.pbm</bitmap>
  8.     <cantDelete> <false /> </cantDelete>
  9.     <showPict> <true /> </showPict>
  10.     <dontSearch> <false /> </dontSearch>
  11.     <owner>2706</owner>
  12.     <link rel="stylesheet" type="text/css" href="stylesheet_3135.css" />
  13.     <part>
  14.         <id>1</id>
  15.         <type>field</type>
  16.         <visible> <true /> </visible>
  17.         <dontWrap> <false /> </dontWrap>
  18.         <dontSearch> <false /> </dontSearch>
  19.         <sharedText> <false /> </sharedText>
  20.         <fixedLineHeight> <false /> </fixedLineHeight>
  21.         <autoTab> <false /> </autoTab>
  22.         <lockText> <true /> </lockText>
  23.         <rect>
  24.             <left>225</left>
  25.             <top>52</top>
  26.             <right>398</right>
  27.             <bottom>187</bottom>
  28.         </rect>
  29.         <style>scrolling</style>
  30.         <autoSelect> <false /> </autoSelect>
  31.         <showLines> <false /> </showLines>
  32.         <wideMargins> <false /> </wideMargins>
  33.         <multipleLines> <false /> </multipleLines>
  34.         <reservedFamily> 0 </reservedFamily>
  35.         <titleWidth>0</titleWidth>
  36.         <icon>0</icon>
  37.         <textAlign>left</textAlign>
  38.         <font>Geneva</font>
  39.         <textSize>12</textSize>
  40.         <textStyle>plain</textStyle>
  41.         <textHeight>16</textHeight>
  42.         <name></name>
  43.         <script></script>
  44.     </part>
  45.     <part>
  46.         <id>2</id>
  47.         <type>field</type>
  48.         <visible> <true /> </visible>
  49.         <dontWrap> <false /> </dontWrap>
  50.         <dontSearch> <false /> </dontSearch>
  51.         <sharedText> <false /> </sharedText>
  52.         <fixedLineHeight> <false /> </fixedLineHeight>
  53.         <autoTab> <false /> </autoTab>
  54.         <lockText> <true /> </lockText>
  55.         <rect>
  56.             <left>20</left>
  57.             <top>52</top>
  58.             <right>209</right>
  59.             <bottom>115</bottom>
  60.         </rect>
  61.         <style>transparent</style>
  62.         <autoSelect> <false /> </autoSelect>
  63.         <showLines> <false /> </showLines>
  64.         <wideMargins> <false /> </wideMargins>
  65.         <multipleLines> <false /> </multipleLines>
  66.         <reservedFamily> 0 </reservedFamily>
  67.         <titleWidth>0</titleWidth>
  68.         <icon>0</icon>
  69.         <textAlign>left</textAlign>
  70.         <font>Geneva</font>
  71.         <textSize>9</textSize>
  72.         <textStyle>plain</textStyle>
  73.         <textHeight>12</textHeight>
  74.         <name></name>
  75.         <script>on mouseUp
  76. put empty into me
  77. end mouseUp</script>
  78.     </part>
  79.     <part>
  80.         <id>3</id>
  81.         <type>button</type>
  82.         <visible> <true /> </visible>
  83.         <reserved5> 0 </reserved5>
  84.         <reserved4> 0 </reserved4>
  85.         <reserved3> 0 </reserved3>
  86.         <reserved2> 0 </reserved2>
  87.         <reserved1> 0 </reserved1>
  88.         <enabled> <true /> </enabled>
  89.         <rect>
  90.             <left>62</left>
  91.             <top>153</top>
  92.             <right>162</right>
  93.             <bottom>175</bottom>
  94.         </rect>
  95.         <style>shadow</style>
  96.         <showName> <true /> </showName>
  97.         <highlight> <false /> </highlight>
  98.         <autoHighlight> <true /> </autoHighlight>
  99.         <sharedHighlight> <true /> </sharedHighlight>
  100.         <family>0</family>
  101.         <titleWidth>0</titleWidth>
  102.         <icon>0</icon>
  103.         <textAlign>center</textAlign>
  104.         <font>Chicago</font>
  105.         <textSize>12</textSize>
  106.         <textStyle>plain</textStyle>
  107.         <name>Try it!</name>
  108.         <script>on mouseUp
  109. put empty into cd fld 2
  110. -- put GetDefaultFile("Hard Drive:Folder", "TEXT") into this
  111. put GetDefaultFile("Hard Drive:Folder") into this
  112. put this into cd fld 2
  113. end mouseUp</script>
  114.     </part>
  115.     <content>
  116.         <layer>card</layer>
  117.         <id>1</id>
  118.         <text><span class="style2">n XFCN which will open a standard SFGetFile dialog box at a given path. This will override the "Documents" setup in the General Controls Control Panel when using System 7.5.
  119.  
  120. Calling syntax: GetDefaultFile ( <path>, [<type>] )
  121.  
  122. Type is a filter for specific file types like 'TEXT' or 'rsrc' and is optional.
  123.  
  124. Using "!" and "?" as a parameter will return an on-line help (resp. copyright and syntax).</span></text>
  125.     </content>
  126.     <name>GetDefaultFile</name>
  127.     <script>on openCard
  128. put empty into cd fld 2
  129. end openCard
  130.  
  131. </script>
  132. </card>
  133.  
  134.  
  135. card_8277.xml
  136. <?xml version="1.0" encoding="utf-8" ?>
  137. <!DOCTYPE card PUBLIC "-//Apple, Inc.//DTD card V 2.0//EN" "" >
  138. <card>
  139.     <id>8277</id>
  140.     <filler1>0</filler1>
  141.     <cantDelete> <false /> </cantDelete>
  142.     <showPict> <true /> </showPict>
  143.     <dontSearch> <false /> </dontSearch>
  144.     <owner>8637</owner>
  145.     <link rel="stylesheet" type="text/css" href="stylesheet_3135.css" />
  146.     <part>
  147.         <id>4</id>
  148.         <type>field</type>
  149.         <visible> <true /> </visible>
  150.         <dontWrap> <false /> </dontWrap>
  151.         <dontSearch> <false /> </dontSearch>
  152.         <sharedText> <false /> </sharedText>
  153.         <fixedLineHeight> <false /> </fixedLineHeight>
  154.         <autoTab> <false /> </autoTab>
  155.         <lockText> <true /> </lockText>
  156.         <rect>
  157.             <left>2</left>
  158.             <top>28</top>
  159.             <right>414</right>
  160.             <bottom>214</bottom>
  161.         </rect>
  162.         <style>scrolling</style>
  163.         <autoSelect> <false /> </autoSelect>
  164.         <showLines> <false /> </showLines>
  165.         <wideMargins> <false /> </wideMargins>
  166.         <multipleLines> <false /> </multipleLines>
  167.         <reservedFamily> 0 </reservedFamily>
  168.         <titleWidth>0</titleWidth>
  169.         <icon>0</icon>
  170.         <textAlign>left</textAlign>
  171.         <font>Geneva</font>
  172.         <textSize>9</textSize>
  173.         <textStyle>plain</textStyle>
  174.         <textHeight>12</textHeight>
  175.         <name>Credits</name>
  176.         <script>on mouseUp
  177. visual dissolve
  178. go back
  179. end mouseUp</script>
  180.     </part>
  181.     <part>
  182.         <id>5</id>
  183.         <type>button</type>
  184.         <visible> <true /> </visible>
  185.         <reserved5> 0 </reserved5>
  186.         <reserved4> 0 </reserved4>
  187.         <reserved3> 0 </reserved3>
  188.         <reserved2> 0 </reserved2>
  189.         <reserved1> 0 </reserved1>
  190.         <enabled> <true /> </enabled>
  191.         <rect>
  192.             <left>389</left>
  193.             <top>5</top>
  194.             <right>409</right>
  195.             <bottom>24</bottom>
  196.         </rect>
  197.         <style>transparent</style>
  198.         <showName> <false /> </showName>
  199.         <highlight> <false /> </highlight>
  200.         <autoHighlight> <true /> </autoHighlight>
  201.         <sharedHighlight> <true /> </sharedHighlight>
  202.         <family>0</family>
  203.         <titleWidth>0</titleWidth>
  204.         <icon>130</icon>
  205.         <textAlign>center</textAlign>
  206.         <font>Chicago</font>
  207.         <textSize>12</textSize>
  208.         <textStyle>plain</textStyle>
  209.         <name>Help</name>
  210.         <script>on mouseUp
  211. visual dissolve
  212. go back
  213. end mouseUp</script>
  214.     </part>
  215.     <part>
  216.         <id>6</id>
  217.         <type>button</type>
  218.         <visible> <true /> </visible>
  219.         <reserved5> 0 </reserved5>
  220.         <reserved4> 0 </reserved4>
  221.         <reserved3> 0 </reserved3>
  222.         <reserved2> 0 </reserved2>
  223.         <reserved1> 0 </reserved1>
  224.         <enabled> <true /> </enabled>
  225.         <rect>
  226.             <left>364</left>
  227.             <top>5</top>
  228.             <right>384</right>
  229.             <bottom>24</bottom>
  230.         </rect>
  231.         <style>opaque</style>
  232.         <showName> <false /> </showName>
  233.         <highlight> <false /> </highlight>
  234.         <autoHighlight> <false /> </autoHighlight>
  235.         <sharedHighlight> <true /> </sharedHighlight>
  236.         <family>0</family>
  237.         <titleWidth>0</titleWidth>
  238.         <icon>132</icon>
  239.         <textAlign>center</textAlign>
  240.         <font>Chicago</font>
  241.         <textSize>12</textSize>
  242.         <textStyle>plain</textStyle>
  243.         <name>Help</name>
  244.         <script>on mouseUp
  245. end mouseUp</script>
  246.     </part>
  247.     <content>
  248.         <layer>card</layer>
  249.         <id>4</id>
  250.         <text>GetDefaultFile is an XFCN that will open a standard SFGetFile dialog at a given path. It is one of the many externals found in the Core Collection v2.1. I hope someone finds it useful.
  251.  
  252. -- Legal Stuff
  253. This  external is  FreeWare, allowing unlimited use in any non-commercial stack. You just need in this case to mention the author's name and copyright in your stack. Any commercial use must be licensed and acknowledged by the author.
  254.  
  255. Internet:   sudderth@traveller.com
  256. Web:   http://www.hsv.tis.net/~sudderth
  257.  
  258. ¬© 1991-1996 All Rights Reserved
  259. Core Development Group, Inc. / Written by John Sudderth     
  260. If you would like an external developed for your company just drop us a line.
  261.  
  262. Version history:
  263.  
  264. v1.1 - Added optional "Type" parameter. Dialog now opens with first item selected (instead of the last).</text>
  265.     </content>
  266.     <name>Credits</name>
  267.     <script>on openCard
  268. set scroll of cd fld 1 to 0
  269. end openCard
  270.  
  271.  
  272.  
  273.  
  274. </script>
  275. </card>
  276.  
  277.  
  278.